package com.itheima.dao.system;

import com.itheima.domain.system.Permission;
import com.itheima.domain.system.Role;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface RoleDao {
    int save(Role role);

    int delete(String id);

    int update(Role role);

    Role findById(String id);

    List<Role> findAll();

    List<Permission> findPermissionsByRoleId(String roleId);

    void deleteRolePermission(String roleId);

    void saveRolePermission(@Param("permissionId") String permissionId,@Param("roleId") String roleId);
}

